<%@ page import="com.ama.utils.SpringUtils" %>
<%@ page import="com.ama.pojo.*" %>
<%@ page import="com.ama.utils.DateUtil" %>
<%@ page import="com.ama.service.impl.*" %>
<%@ page import="com.ama.service.*" %>
<%@ page import="com.ama.dao.BuildDao" %>
<%@ page import="com.ama.dao.EstateDao" %>
<%@ page import="org.springframework.cglib.core.SpringNamingPolicy" %>
<%@ page import="com.ama.dao.RoomDao" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html lang="zh">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"/>
    <title>添加房间</title>
    <link rel="icon" href="favicon.ico" type="image/ico">
    <meta name="keywords" content="">
    <meta name="description" content="">
    <meta name="author" content="">
    <link href="../css/bootstrap.min.css" rel="stylesheet">
    <link href="../css/materialdesignicons.min.css" rel="stylesheet">
    <link href="../css/style.min.css" rel="stylesheet">
    <style type="text/css">
        input[readonly],
        .form-control[readonly]{
            background-color: #FFFFFF;
        }
    </style>
</head>

<%
    BuildDao buildDao = SpringUtils.getBean(BuildDao.class);
    EstateDao estateDao = SpringUtils.getBean(EstateDao.class);
    RoomDao roomDao = SpringUtils.getBean(RoomDao.class);


    Build build = buildDao.selectById(request.getParameter("buildIde"));
    Estate estate = estateDao.selectByPrimaryKey(build.getEstateId());


%>


<body>
<div class="container-fluid p-t-15">

    <div class="row">
        <div class="col-lg-12">
            <div class="card">

                <div class="card-body">

                    <form id="p_staffAddForm" action="/addRoom" method="post" class="guide-box" >

                        <hr>
                        <div class=" text-center m-b-10"><h4>房间信息</h4></div>
                        <hr>

                        <div class="row m-b-10">
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">小区ID*</button>
                                    </span>
                                    <input name="estateId" type="text" readonly value="<%=estate.getEstateId()%>" class="form-control">
                                </div>
                            </div>
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">楼栋ID*</button>
                                    </span>
                                    <input name="buildId" type="text" readonly value="<%=build.getBuildId()%>" class="form-control">
                                </div>
                            </div>
                        </div>

                        <div class="row m-b-10">
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间ID*</button>
                                    </span>
                                    <input name="roomId" type="text"  class="form-control">
                                </div>
                            </div>
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间名</button>
                                    </span>
                                    <input name="roomName" type="text" class="form-control">
                                </div>
                            </div>
                        </div>

                        <div class="row m-b-10">
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间楼层*</button>
                                    </span>
                                    <input name="roomFloor" type="text"  class="form-control">
                                </div>
                            </div>
                        </div>

                        <div class="row m-b-10">
                            <div class="col-lg-4 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间可用面积*</button>
                                    </span>
                                    <input name="roomEffectarea" type="text"   class="form-control">
                                </div>
                            </div>
                            <div class="col-lg-4 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间租用面积*</button>
                                    </span>
                                    <input name="roomRentarea" type="text" class="form-control"
                                    >
                                </div>
                            </div>
                            <div class="col-lg-4 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间公共面积*</button>
                                    </span>
                                    <input name="roomPublicarea" type="text" class="form-control">
                                </div>
                            </div>
                        </div>

                        <div class="row m-b-10">
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间租用单价*</button>
                                    </span>
                                    <input name="roomPrice" type="text" class="form-control">
                                </div>
                            </div>
                            <div class="col-lg-6 m-b-10">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">床位数*</button>
                                    </span>
                                    <input name="bednum" type="text" class="form-control">
                                </div>
                            </div>
                        </div>

                        <div class="row m-b-10">
                            <div class="col-lg-6">
                                <div class="input-group">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间用途</button>
                                    </span>
                                    <input name="roomuse" type="text" class="form-control">
                                </div>
                            </div>

                        </div>


                        <div class="row m-b-10">
                            <div class="col-lg-3 m-b-10 ">
                                <div class="input-group ">
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">房间状态</button>
                                    </span>
                                    <select class="form-control" name="room_state">
                                        <option value="1">空闲</option>
                                        <option value="-1">无空位</option>
                                    </select>
                                </div>
                            </div>
                            <div class="col-lg-3 m-b-10">
                                <div class="input-group" >
                                    <span class="input-group-btn">
                                      <button class="btn btn-default" type="button">开启状态</button>
                                    </span>
                                    <select class="form-control" name="room_open">
                                        <option value="1">开启</option>
                                        <option value="-1">禁用</option>
                                    </select>
                                </div>
                            </div>

                        </div>
                        <div class="row m-b-10">
                            <div class="col-lg-9 ">
                                <div class="form-group">
                                    <span class="input-group-btn">
                                          <button class="btn btn-default" type="button">房间简介</button>
                                    </span>
                                </div>
                            </div>
                            <div class="col-lg-9" style="margin-top: -10px">
                                <textarea name="roomInfo" class="form-control"  rows="6" placeholder="请输入申请原因"></textarea>
                            </div>
                        </div>

                        <hr>

                        <div class="nav-step-button">
                            <a href="p_estatemanage.jsp">
                                <button class="btn btn-secondary" data-wizard="prev" type="button">
                                    返回
                                </button>
                            </a>
                            <div class="text-center">
                                <button type="submit" class="btn btn-primary">添加</button>
                            </div>
                        </div>
                        <hr>

                    </form>
                </div>
            </div>
        </div>

    </div>

</div>

<%--输入检查--%>
<script type="text/javascript" src="../js/pro_pageJS/p_staffDetailCheck.js"></script>

<script type="text/javascript" src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../js/bootstrap.min.js"></script>
<script type="text/javascript" src="../js/main.min.js"></script>
<!--向导插件-->
<script type="text/javascript" src="../js/jquery.bootstrap.wizard.min.js"></script>

</body>
</html>
